import 'package:fish_redux/fish_redux.dart';
import 'package:flutter/material.dart' hide Action;

import 'action.dart';
import 'state.dart';

Effect<IndexState> buildEffect() {
  return combineEffects(
      <Object, Effect<IndexState>>{IndexAction.onJump: _onJump});
}

void _onJump(Action action, Context<IndexState> ctx) {
  Navigator.of(ctx.context)
      .pushNamed('edit', arguments: null)
      .then((dynamic toDo) {});
}
